package top.maof.book.model;

import com.baomidou.mybatisplus.annotation.*;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;

/**
 * 书的评分
 * 每个人只能对一本书评分一次
 *
 * @author 毛逢
 * @date 2021/5/24 15:36
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("score")
public class Score implements Serializable {
    @TableId(type = IdType.AUTO)
    private Integer id;
    private Integer userId;
    private Integer bookId;
    private Double score;
    private Long time;

    @TableField(fill = FieldFill.INSERT)
    private Long insertTime;

    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Long updateTime;
}
